<?php
/**
*
* @package phpBB
* @version $Id: ajax.php 0 30 dec 2008 22:09:36 Alexander de Jong $
* @copyright (c) 2005 phpBB Group
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/

/**
* @ignore
*/
if (!defined('IN_PHPBB'))
{
	exit;
}

/**
* get_cookie
* 
* This function will get a cookie and returns it to ajax.
* 
* @param string $cookie_name 
*/
$xajax->registerFunction('get_cookie');
function get_cookie($cookie_name)
{
	$xjsres = new xajaxResponse();
	$js = "var $cookie_name = " . request_var($cookie_name, null, false, true);
	$xjsres->script($js);
	return $xjsres;
}

$xajax->processRequest();
?>